The public policy behind privileged communications is that we want people to be able to seek help without fear of reprisal or prosecution. The idea is that it is more important for people to get help than to punish them for prior bad acts. There are only a handful of legally protected relationships in the US and the law is not uniform, some are social worker-client, attorney-client, religious cleric-parishioner, psychologist-patient, spousal privilege, reporter-source and doctor-patient.
The privilege protects the communication between the parties from being subject to legal subpoena and being used as evidence against an individual. The privilege does not protect the threat of futured illegal acts or contemplated harm, only acts in the past.
It can be difficult at best to weigh the competing interests between wanting people to seek help and prosecuting them for prior crimes. There is an old saying that hard cases make bad laws, meaning that basing a law on a particularly difficult set of facts or bad outcome is not always the best idea.
Would we rather someone get counseling and perhaps stop whatever it is they are doing, or would we rather see that they are punished? If we begin carving out exceptions to the privilege rule that is usually a slippery slope towards nullifying it.
Also, I suspect most of the time the professional will admonish the confessor to cease their activities and even confess and accept punishment for them. I can see the value of a patient being able to tell his physician that he has been ingesting illegal drugs so that the doctor may treat him properly without worrying about the physician calling the police and reporting him after he leaves the office or a reporter being able to protect a source that delivers important information about some wrongdoing so that they don't have to fear for their life.
All privilege is like any other law or rule, it's a line we draw in the sand and there will always be situations just on the other side of the line that we don't like. I hate it that pedophiles can be shielded from prosecution due to clerical privilege but I'm not sure what the answer is as I believe privilege has sound public policy behind it.